cmake_minimum_required(VERSION 2.6)

find_path    (PTHREAD_INCLUDE NAMES pthread.h)
find_library (PTHREAD_LIBRARY pthread)

set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -pedantic -Wextra -Weffc++")
set( SOURCES
            multih.cpp
            multih_server.cpp
            connection_manager.cpp
            connection_handler.cpp
            handler_pool.cpp
            http.cpp
            file_handler.cpp )

include_directories(${PTHREAD_INCLUDE})

add_executable(multih ${SOURCES})
target_link_libraries(multih ${PTHREAD_LIBRARY})
